Distance transformation and density-weighted distance transformation are supposed to be the best ways to compress image data or to extract characteristics of images. There are two types of the above processes: sequential process and parallel process. Since the sequential process is difficult to perform by hardware, it cannot be performed in high speed. The parallel process has disadvantages in that the distance value is biased according to scanning direction when processed by one scanning. So parallel process needs multiple scanning.
For example, as to the image of 4.times.4 pixels in FIG. 1, when a parallel process with 3.times.3 convolutions is performed, the hatched pixel of coordinate (3,3) is given a distance value of "3" according to the distance from boundaries of upper and left sides. The distance from the right side boundary cannot be found by one scanning. However, the distance of this pixel is "2" from boundaries of right and lower side: this means that a bias is arisen from the scanning direction. For improving this disadvantage, one more scanning is necessary. This means that the bigger an image is, the more the number of scanning increases.